//
//  OosEnum.h
//  oos4ios
//
//  Created by Pablo Gonzalez on 3/4/11.
//

#import <Foundation/Foundation.h>

/**
 Interface to emulate the more functional enum in Java
 */
@interface OosEnum : NSObject
{
	NSUInteger mOrdinal;
	NSString *mDescription;
}

@property (nonatomic, retain, readonly) NSString *description;
@property (nonatomic, readonly) NSUInteger ordinal;

+ (NSArray *) values;

+ (id) enumForPosition: (NSUInteger) position;

+ (id) enumFromLiteral: (NSString *) literal;

+ (id) enumWithDescription: (NSString *) description
                andOrdinal:(NSUInteger) ordinal;

- (id) initWithDescription: (NSString *) description
                andOrdinal:(NSUInteger) ordinal;

+ (NSMutableDictionary *) enums;

@end
